package com.weipai.springboot.model;

import com.weipai.springboot.module.util.DateUtils;

import javax.persistence.Column;
import javax.persistence.Id;
import javax.persistence.Table;
import java.util.UUID;

/**
 * 积分商品实体类
 */
@Table(name = "c_integral_goods")
public class IntegralGoods {

    @Id
    private String integralGoodsId= UUID.randomUUID().toString();//主键

    private String goodsId;//商品的id

    private String goodsCategoryId;//商品类别id

    private Integer theIntegral;//兑换商品所需的积分

    private Integer integralGoodsStatus=0;//状态值：启用--0，-1禁用

    private Integer integralGoodsDel=0;//逻辑删除：0默认，-1删除

    private Integer integralGoodsSort=0;//排序

    private Integer integralGoodsNumber;//积分商品的数量

    private Integer soldOutNumber=0;//已兑换的数量

    private String createTime= DateUtils.timeFormat(System.currentTimeMillis());//创建时间

    private String delTime;//删除时间   

    private String updateTime;//修改时间

    public String getIntegralGoodsId() {
        return integralGoodsId;
    }

    public void setIntegralGoodsId(String integralGoodsId) {
        this.integralGoodsId = integralGoodsId;
    }

    public String getGoodsId() {
        return goodsId;
    }

    public void setGoodsId(String goodsId) {
        this.goodsId = goodsId == null ? null : goodsId.trim();
    }

    public String getGoodsCategoryId() {
        return goodsCategoryId;
    }

    public void setGoodsCategoryId(String goodsCategoryId) {
        this.goodsCategoryId = goodsCategoryId == null ? null : goodsCategoryId.trim();
    }

    public Integer getTheIntegral() {
        return theIntegral;
    }

    public void setTheIntegral(Integer theIntegral) {
        this.theIntegral = theIntegral;
    }

    public Integer getIntegralGoodsStatus() {
        return integralGoodsStatus;
    }

    public void setIntegralGoodsStatus(Integer integralGoodsStatus) {
        this.integralGoodsStatus = integralGoodsStatus;
    }

    public Integer getIntegralGoodsDel() {
        return integralGoodsDel;
    }

    public void setIntegralGoodsDel(Integer integralGoodsDel) {
        this.integralGoodsDel = integralGoodsDel;
    }

    public Integer getIntegralGoodsSort() {
        return integralGoodsSort;
    }

    public void setIntegralGoodsSort(Integer integralGoodsSort) {
        this.integralGoodsSort = integralGoodsSort;
    }

    public Integer getIntegralGoodsNumber() {
        return integralGoodsNumber;
    }

    public void setIntegralGoodsNumber(Integer integralGoodsNumber) {
        this.integralGoodsNumber = integralGoodsNumber;
    }

    public Integer getSoldOutNumber() {
        return soldOutNumber;
    }

    public void setSoldOutNumber(Integer soldOutNumber) {
        this.soldOutNumber = soldOutNumber;
    }

    public String getCreateTime() {
        return createTime;
    }

    public void setCreateTime(String createTime) {
        this.createTime = createTime == null ? null : createTime.trim();
    }

    public String getDelTime() {
        return delTime;
    }

    public void setDelTime(String delTime) {
        this.delTime = delTime == null ? null : delTime.trim();
    }

    public String getUpdateTime() {
        return updateTime;
    }

    public void setUpdateTime(String updateTime) {
        this.updateTime = updateTime == null ? null : updateTime.trim();
    }
}